/*
 This program is submitted as part of an assignment in the
 J2E
 Fall Semester 2010-2011 
 School of Computer Science
 Interdisciplinary Center, Hertzelia, Israel 

 http://www.idc.ac.il 

 Exercise No.         : 3
 File Name            : OpeningScreenActivity.java
 Names (First Last)   : Itay Sorani, Nadav Ziv, Yonathan Zarsky
 Student No.          : 066530254, 039937883, 039692918

 */

package com.example;

import android.content.*;
import android.os.Bundle;
import android.view.*;
import android.widget.*;

/**
 * The OpeningScreenActivity class. an extension of the base activity, sets the the activity for
 * the opening screen of the game.
 */
public class OpeningScreenActivity extends BaseActivity {

    private Button gotoGameButton, exitButton;

	@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.opening_screen);
        gotoGameButton = (Button)findViewById(R.id.startButton);
        exitButton = (Button)findViewById(R.id.exit);
        gotoGameButton.setOnClickListener(new View.OnClickListener() {
            public void onClick(View view) {
                startActivity(new Intent(OpeningScreenActivity.this, GameActivity.class));
            }
        });
        exitButton.setOnClickListener(new View.OnClickListener() {
            public void onClick(View view) {
            	finish();
            }
        });
    }
}